/*
 * ServerSocket.h
 *
 *  Created on: 07.10.2012
 *      Author: Sven
 */

#ifndef SERVERSOCKET_H_
#define SERVERSOCKET_H_

class CServerSocket
{
public:
	CServerSocket() { m_handle = 0; memset(&m_addr, 0, sizeof(sockaddr_in)); }
	~CServerSocket() {}

	static DWORD run(CServerSocket* socket);

	int init(int port);
	void close();

	void recvp();
	void sendp();

	void recvs();
	void sends();

private:
	int								m_handle;
	sockaddr_in						m_addr;
};

#endif /* SERVERSOCKET_H_ */
